package com.zx.mes.demo.hyl;

import java.io.File;

/**
 * test user.dir
 *
 * @author 华云龙
 * @date 2019-2-15
 */
public class Test {

    public static void main(String[] args) {
        System.out.println(System.getProperty("user.dir"));
        File directory = new File("hyl");
        System.out.println(directory.getAbsolutePath());
        String path = Test.class.getResource("/").getPath();
        System.out.println(path);
        System.out.println(path.indexOf("/target"));
        System.out.println(path.substring(0,path.indexOf("/target")));
    }
}
